paparazzi-devel
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [Paparazzi-devel] Using GDB server for flashing and debugging.


From: Jake Stewart
Subject: Re: [Paparazzi-devel] Using GDB server for flashing and debugging.
Date: Mon, 19 Mar 2012 15:24:07 -0400

After a little more looking around it seems that perhaps this is the right line 
in the airframe file...
<configure name="FLASH_MODE" value="JTAG"/>

Then I should be able to change Makefile.stm32... ???
/opt/paparazzi/stm32/bin/arm-none-eabi-gdbtui --eval-command="target remote 
localhost:3333"
to
/opt/paparazzi/stm32/bin/arm-none-eabi-gdbtui --eval-command="target remote 
192.168.56.1:61234"

I also see there's a "BMP_PORT" setting in the makefile.  If I define that I 
take it that it will use OOCD?  So would I just add "<define name="BMP_PORT"/>" 
or <define name="BMP_PORT" value="1"/> to my airframe file?  Do I need to do 
this for each target or can I define it outside the target and have it work for 
all target configs?

Do I then need to change OOCD configuration settings?

--------------------

I've just run into another problem...
/opt/paparazzi/arm-multilib/lib/gcc/arm-none-eabi/4.6.2/../../../../arm-none-eabi/bin/ld:
 /home/jake/paparazzi/var/VLD/ap/ap.elf section `._usrstack' will not fit in 
region `RAM'
/opt/paparazzi/arm-multilib/lib/gcc/arm-none-eabi/4.6.2/../../../../arm-none-eabi/bin/ld:
 region `RAM' overflowed by 2012 bytes

I'm using the F103RB linker script, stm32f103rb_flash.ld.  Hopefully set in my 
airframe config by...
<define name="LDSCRIPT" value="$(SRC_ARCH)/stm32f103rb_flash.ld"/>

Any help appreciated.


-Jake

> ----- Original Message -----
> From: Jake Stewart
> Sent: 03/19/12 11:29 AM
> To: address@hidden
> Subject: [Paparazzi-devel] Using GDB server for flashing and debugging.
> 
> I'm currently running Lubuntu in a VirtualBox and after a few attempts to get 
> a linux gdb server using a stlink, I've given up on that route.  Not sure if 
> it's a USB issue, ST's broken implementation of SCSI commands in the ST-Link, 
> or just that I don't understand the modprobe configuration well enough.
> 
> So what I'd like to do is run the GDB server using the stlink in windows.  
> I've already got this working, but I'm having trouble figuring out how to 
> configure paparazzi to use the GDB server for flashing.
> 
> I found this line in one of the airframe files...
> <configure name="FLASH_MODE" values="IAP|JTAG|ISP"/>
> 
> Typing that into my airframe with "GDB" as the value just throws an error.
> 
> Is anyone else using a GDB server?  Anyone have any ideas to help me out?
> 
> -Jake
> 
> P.S. Sorry about the "deal" message to the list, somebody hacked my email and 
> sent out stupid one line messages to everyone in my contact list.
> 
> I've also attached my airframe config if it's any help.
> 
> --------------------------------------------
> <!DOCTYPE airframe SYSTEM "airframe.dtd">
> <!-- Test info here...-->
> 
> <airframe name="VLD">
> 
> <firmware name="fixedwing">
>     <target name="sim" board="pc" />
>     <target name="jsbsim"       board="pc"/>
>     <target name="ap" board="VL_Discovery_1.0">
>       <define name="LDSCRIPT" value="$(SRC_ARCH)/stm32f103rb_flash.ld"/>
>       <configure name="FLASH_MODE" values="GDB"/>
>     </target>
> 
>     <subsystem name="radio_control"     type="datalink">
>  <configure name="RADIO_CONTROL_LED" value="none"/>
>  </subsystem>
> 
>     <!-- Communication -->
>     <subsystem name="telemetry" type="transparent">
>      <configure name="MODEM_BAUD" value="B9600"/>
>     </subsystem>
> 
>     <subsystem name="control"/>
>     <!-- Sensors -->
> 
>     <subsystem name="imu"       type="aspirin_v1.5">
>     </subsystem>
> 
>     <subsystem name="ahrs"      type="int_cmpl_euler"/>
> 
> 
>  <subsystem name="gps" type="nmea"/>
>     <subsystem name="navigation"/>
> 
>   </firmware>
> 
>   <firmware name="lisa_test_progs">
>     <target name="test_led"            board="lisa_m_1.0"/>
>     <target name="test_uart"           board="lisa_m_1.0"/>
>     <target name="test_servos"         board="lisa_m_1.0"/>
>     <target name="test_telemetry"      board="lisa_m_1.0">
>       <configure name="MODEM_PORT" value="UART2"/>
>     </target>
>     <target name="test_bmp085"         board="lisa_m_1.0"/>
>     <target name="test_esc_mkk_simple" board="lisa_m_1.0"/>
>     <target name="test_rc_spektrum"    board="lisa_m_1.0"/>
>     <target name="test_manual"         board="lisa_m_1.0"/>
>     <target name="test_esc_mkk_simple" board="lisa_m_1.0"/>
>     <target name="test_hmc5843"        board="lisa_m_1.0"/>
>     <target name="test_itg3200"        board="lisa_m_1.0"/>
>     <target name="test_adxl345"        board="lisa_m_1.0"/>
>     <target name="test_adc"            board="lisa_m_1.0"/>
>   </firmware>
> 
>   <servos>
>  <servo name="THROTTLE"  no="7" min="1200" neutral="1200" max="2000"/>
>     <servo name="AILERON" no="4" min="1000" neutral="1500" max="2000"/>
>     <servo name="ELEVATOR" no="3" min="1000" neutral="1500" max="2000"/>
>  <servo name="RUDDER" no="5" min="1000" neutral="1500" max="2000"/>
>   </servos>
> 
>   <commands>
>     <axis name="THROTTLE" failsafe_value="0"/>
>     <axis name="ROLL"     failsafe_value="0"/>
>     <axis name="PITCH"    failsafe_value="0"/>
>     <axis name="YAW"     failsafe_value="0"/>
>   </commands>
> 
>   <rc_commands>
>     <set command="THROTTLE" value="@THROTTLE"/>
>     <set command="ROLL"     value="@ROLL"/>
>     <set command="PITCH"    value="@PITCH"/>
>     <set command="YAW"     value="@YAW"/>
>   </rc_commands>
> 
>   <command_laws>
>     <set servo="THROTTLE" value="@THROTTLE"/>
>     <set servo="AILERON"  value="@ROLL"/>
>     <set servo="ELEVATOR"  value="@PITCH"/>
>  <set servo="RUDDER"  value="@YAW"/>
>   </command_laws>
> 
>   <section name="AUTO1" prefix="AUTO1_">
>     <define name="MAX_ROLL" value="0.7"/>
>     <define name="MAX_PITCH" value="0.6"/>
>   </section>
> 
>   <section name="BAT">
>     <define name="MILLIAMP_AT_FULL_THROTTLE" value="2000"/>
>     <define name="CATASTROPHIC_BAT_LEVEL" value="9.3" unit="V"/>
>   </section>
> 
>   <section name="MISC">
>     <define name="NOMINAL_AIRSPEED" value="13." unit="m/s"/>
>     <define name="CARROT" value="5." unit="s"/>
>     <define name="KILL_MODE_DISTANCE" value="(1.5*MAX_DIST_FROM_HOME)"/>
>     <define name="CONTROL_RATE" value="60" unit="Hz"/>
>     <define name="ALT_KALMAN_ENABLED" value="TRUE"/>
>     <define name="DEFAULT_CIRCLE_RADIUS" value="80."/>
>   </section>
> 
>   <section name="VERTICAL CONTROL" prefix="V_CTL_">
>     <define name="POWER_CTL_BAT_NOMINAL" value="11.1" unit="volt"/>
> 
>     <!-- outer loop proportional gain -->
>     <define name="ALTITUDE_PGAIN" value="-0.03"/>
> 
>     <!-- outer loop saturation -->
>     <define name="ALTITUDE_MAX_CLIMB" value="2."/>
> 
>     <!-- auto throttle inner loop -->
>     <define name="AUTO_THROTTLE_NOMINAL_CRUISE_THROTTLE" value="0.32"/>
>     <define name="AUTO_THROTTLE_MIN_CRUISE_THROTTLE" value="0.25"/>
>     <define name="AUTO_THROTTLE_MAX_CRUISE_THROTTLE" value="0.65"/>
>     <define name="AUTO_THROTTLE_LOITER_TRIM" value="1500"/>
>     <define name="AUTO_THROTTLE_DASH_TRIM" value="-4000"/>
>     <define name="AUTO_THROTTLE_CLIMB_THROTTLE_INCREMENT" value="0.15" 
> unit="%/(m/s)"/>
>     <define name="AUTO_THROTTLE_PGAIN" value="-0.01"/>
>     <define name="AUTO_THROTTLE_IGAIN" value="0.1"/>
>     <define name="AUTO_THROTTLE_PITCH_OF_VZ_PGAIN" value="0.05"/>
>     <define name="THROTTLE_SLEW_LIMITER" value="2" unit="s"/>
>   </section>
> 
>   <section name="HORIZONTAL CONTROL" prefix="H_CTL_">
>     <define name="COURSE_PGAIN" value="-1.0"/>
>     <define name="COURSE_DGAIN" value="0.3"/>
> 
>     <define name="ROLL_MAX_SETPOINT" value="0.6" unit="rad"/>
>     <define name="PITCH_MAX_SETPOINT" value="0.5" unit="rad"/>
>     <define name="PITCH_MIN_SETPOINT" value="-0.5" unit="rad"/>
> 
>     <define name="PITCH_PGAIN" value="-12000."/>
>     <define name="PITCH_DGAIN" value="1.5"/>
> 
>     <define name="ELEVATOR_OF_ROLL" value="1250"/>
> 
>     <define name="ROLL_SLEW" value="0.1"/>
> 
>     <define name="ROLL_ATTITUDE_GAIN" value="-7500"/>
>     <define name="ROLL_RATE_GAIN" value="-1500"/>
>   </section>
> 
>   <section name="AGGRESSIVE" prefix="AGR_">
>     <define name="BLEND_START" value="20"/><!-- Altitude Error to Initiate 
> Aggressive Climb CANNOT BE ZERO!!-->
>     <define name="BLEND_END" value="10"/><!-- Altitude Error to Blend 
> Aggressive to Regular Climb Modes  CANNOT BE ZERO!!-->
>     <define name="CLIMB_THROTTLE" value="1.00"/><!-- Throttle for Aggressive 
> Climb -->
>     <define name="CLIMB_PITCH" value="0.3"/><!-- Pitch for Aggressive Climb 
> -->
>     <define name="DESCENT_THROTTLE" value="0.1"/><!-- Gaz for Aggressive 
> Decent -->
>     <define name="DESCENT_PITCH" value="-0.25"/><!-- Pitch for Aggressive 
> Decent -->
>     <define name="CLIMB_NAV_RATIO" value="0.8"/><!-- Percent Navigation for 
> Altitude Error Equal to Start Altitude -->
>     <define name="DESCENT_NAV_RATIO" value="1.0"/>
>     </section>
> 
>   <section name="FAILSAFE" prefix="FAILSAFE_">
>     <define name="DELAY_WITHOUT_GPS" value="2" unit="s"/>
>     <define name="DEFAULT_THROTTLE" value="0.3" unit="%"/>
>     <define name="DEFAULT_ROLL" value="0.3" unit="rad"/>
>     <define name="DEFAULT_PITCH" value="0.5" unit="rad"/>
>   </section>
> 
>   <section name="SIMU">
>     <define name="JSBSIM_MODEL" value="&quot;Malolo1&quot;"/>
>     <define name="JSBSIM_IR_ROLL_NEUTRAL" value="0." unit="deg"/>
>     <define name="JSBSIM_IR_PITCH_NEUTRAL" value="0." unit="deg"/>
>   </section>
> 
>  <section name="IMU" prefix="IMU_">
>     <define name="ACCEL_X_NEUTRAL" value="11"/>
>     <define name="ACCEL_Y_NEUTRAL" value="11"/>
>     <define name="ACCEL_Z_NEUTRAL" value="-25"/>
> 
>     <define name="MAG_X_NEUTRAL" value="-98"/>
>     <define name="MAG_Y_NEUTRAL" value="-252"/>
>     <define name="MAG_Z_NEUTRAL" value="-122"/>
>     <define name="MAG_X_SENS" value="4.04659389111" integer="16"/>
>     <define name="MAG_Y_SENS" value="4.07651737489" integer="16"/>
>     <define name="MAG_Z_SENS" value="3.77693466173" integer="16"/>
> 
>     <define name="BODY_TO_IMU_PHI"   value="0." unit="deg"/>
>     <define name="BODY_TO_IMU_THETA" value="0." unit="deg"/>
>     <define name="BODY_TO_IMU_PSI"   value="-45." unit="deg"/>
>   </section>
> 
> 
>   <modules>
> 
>   </modules>
> 
> </airframe>
> 
> _______________________________________________
> Paparazzi-devel mailing list
> address@hidden
> https://lists.nongnu.org/mailman/listinfo/paparazzi-devel



reply via email to

[Prev in Thread] Current Thread [Next in Thread]