Skip to content
This repository has been archived by the owner on Apr 12, 2024. It is now read-only.

Commit

Permalink
Update control pkt in amp_serial_jetson.h to use unsigned char instea…
Browse files Browse the repository at this point in the history
…d of char

Range of char is -128 to 127, we need unsigned values from 0 to 255.
  • Loading branch information
bitmaks committed Apr 4, 2022
1 parent 9704f02 commit 0be57a2
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 4 deletions.
4 changes: 2 additions & 2 deletions src/ti_comm/src/amp_serial_jetson.h
Original file line number Diff line number Diff line change
Expand Up @@ -113,8 +113,8 @@ typedef enum amp_control_state_t {

// DECLARE PACKET DATA STRUCTURES
typedef struct amp_serial_pkt_control_t {
int v_angle; // vehicle steering angle
int v_speed; // vehicle speed
unsigned char v_angle; // vehicle steering angle
unsigned char v_speed; // vehicle speed
} amp_serial_pkt_control_t;

typedef struct amp_serial_pkt_dac_t {
Expand Down
4 changes: 2 additions & 2 deletions src/ti_comm/src/test/amp_serial_jetson.h
Original file line number Diff line number Diff line change
Expand Up @@ -115,8 +115,8 @@ typedef enum amp_control_state_t {

// DECLARE PACKET DATA STRUCTURES
typedef struct amp_serial_pkt_control_t {
char v_speed; // vehicle speed
char v_angle; // vehicle steering angle
unsigned char v_speed; // vehicle speed
unsigned char v_angle; // vehicle steering angle
} amp_serial_pkt_control_t;

typedef struct amp_serial_pkt_dac_t {
Expand Down

0 comments on commit 0be57a2

Please sign in to comment.