Commit graph

183 commits

Author SHA1 Message Date
Dominic Clifton 9fa99cf9f5 Re-organize files by topic
Keil project not updated, I have no way to verify it.

Note, mw.c, drv_pwm.c and drv_system.c contain code for too many topics.
Later commits will relocate the code as appropriate.

Not even looked at utils yet.  'Utils' is a bad naming practice and is a
synonym for 'too lazy to find the right file/name'.
2014-04-08 16:11:17 +01:00
Dominic Clifton 3ca868a59f Enable HoTT as a telemetry provider.
Import cGiensen's HoTT telemetry implementation - untested.
2014-04-06 23:51:48 +01:00
Dominic Clifton 1cbe166c49 Move common telemetry code to telemetry_common.c/.h 2014-04-06 23:10:29 +01:00
Dominic Clifton 2fdadaa78f Rename telemetry.c to telemetry_frsky.c in preparation for adding
another telemetry provider
2014-04-06 21:36:56 +01:00
dongie a695ddd66a added sumd serial receiver support by cesco/Plüschi 2014-01-31 10:02:50 +09:00
dongie f29405ffb0 whitespace fixes in Makefile 2014-01-01 19:19:10 +09:00
Hyon Lim 531aa9e1b5 Update Makefile
# In some cases, %.s regarded as intermediate file, which is actually not.
# This will prevent accidental deletion of startup code.
2013-11-29 02:54:42 +09:00
timecop@gmail.com 203e46daa6 Enable automatic reset after (re)flashing, closes issue #19
git-svn-id: https://afrodevices.googlecode.com/svn/trunk/baseflight@466 7c89a4a9-59b9-e629-4cfe-3a2d53b20e61
2013-11-01 22:47:25 +00:00
timecop@gmail.com 07055c8872 fixing initializion for anglesrad[]
add drv_softserial to common drivers in Makefile

git-svn-id: https://afrodevices.googlecode.com/svn/trunk/baseflight@436 7c89a4a9-59b9-e629-4cfe-3a2d53b20e61
2013-10-12 08:07:08 +00:00
timecop@gmail.com 28d5927836 Totally rework software serial to provide tx at the same time as rx using only one timer.
First cut at polymorphic serial port implementation.  Split serialPort_t into uartPort_t and serialPort_t.  Calls to uartWrite() can now be replaced with calls to serialWrite().

Replacing calls to serialWriteByte(softSerial_t*, char) with calls to serialWrite(serialPort_t*, char).  This completes the proof of concept for polymorphic serial port implementations (uartPort and softSerialPort).

Renaming isSerialAvailable to uartTotalBytesWaiting.  Renaming serialAvailable to softSerialTotalBytesWaiting.  Adding serialTotalBytesWaiting to serial API and updating calls to the former methods to use the serial API.

Renaming serialRead to softSerialRead.  Adding serialRead to serial API and updating calls to uartRead and softSerialRead to use the serial API.  Renamed uartPrint to serialPrint which now works on any serialPort implementation.

Replacing calls to isUartTransmitEmpty with isSoftSerialTransmitBufferEmpty.  Replacing remaing calls to uartWrite with serialWrite.  Adding isSoftSerialTransmitBufferEmpty to the serial API.  Adding serialSet/GetBaudRate to the serial API.  Since softSerial does not implement serialSetBaudRate some GPS serial initialisation code has been updated.

At this point it is probably possible to switch around all the ports and use a software serial implementation if desired.

By Dominic Clifton / https://github.com/hydra/baseflight/

git-svn-id: https://afrodevices.googlecode.com/svn/trunk/baseflight@423 7c89a4a9-59b9-e629-4cfe-3a2d53b20e61
2013-10-01 00:07:44 +00:00
timecop@gmail.com 2272e1a5a6 reorganization of uart-based receiver drivers
FEATURE_SPEKTRUM has been removed and replaced with FEATURE_SERIALRX.
cli  option serialrx_type now configures what type of receiver it is
0 = spektrum1024, 1 = spektrum2048, 2 = sbus
sbus will need hardware inverter to use.
also cleaned up receiver drivers to assign readrawRC callback instead of assigning in code in main()
none of this has been tested.

git-svn-id: https://afrodevices.googlecode.com/svn/trunk/baseflight@418 7c89a4a9-59b9-e629-4cfe-3a2d53b20e61
2013-09-29 14:40:20 +00:00
timecop@gmail.com 6763d8810b added test BMA280 driver
git-svn-id: https://afrodevices.googlecode.com/svn/trunk/baseflight@414 7c89a4a9-59b9-e629-4cfe-3a2d53b20e61
2013-09-29 12:53:02 +00:00
timecop@gmail.com 14893afb32 cleanup of sensor readings and sensor driver API reorganization part 1
documented L3G4200D driver why 0x28 read was suddenly turning into 0xA8
removed old wiimotion averaging cruft from computeIMU
NOT FLIGHT TESTED

git-svn-id: https://afrodevices.googlecode.com/svn/trunk/baseflight@403 7c89a4a9-59b9-e629-4cfe-3a2d53b20e61
2013-09-19 11:20:53 +00:00
dominicc1974@gmail.com 4c191270bf Changing all line endings to WINDOWS line endings (CR+LF) and removing all End-Of-Line whitespace and using spaces instead of tabs. Please ensure you configure your editors and tools to follow suit. If using git please enable autocrlf in your .git/config file.
git-svn-id: https://afrodevices.googlecode.com/svn/trunk/baseflight@393 7c89a4a9-59b9-e629-4cfe-3a2d53b20e61
2013-09-06 23:14:48 +00:00
timecop@gmail.com 77a241bd5f Software serial implementation. Compile with SOFTSERIAL_19200_LOOPBACK to test. Without the define the implementation will have no effect. Next step is to add a 'feature' to enable softserial and settings for the baud rate. Note, only READ is currently supported, write will come later. The highlevel api calls are used in main.c. Uart implementation needs cleanup to make serial port code generic, see uart files for details.
git-svn-id: https://afrodevices.googlecode.com/svn/trunk/baseflight@390 7c89a4a9-59b9-e629-4cfe-3a2d53b20e61
2013-08-28 01:26:10 +00:00
timecop@gmail.com 003c2a91c5 Separate timer code from PWM/PPM code. The method of looking up a callback is now generic which means other (forthcoming) code can configure callback handlers.
Killed some leftovers of GPIO_Pin* stuff I forgot about.

git-svn-id: https://afrodevices.googlecode.com/svn/trunk/baseflight@387 7c89a4a9-59b9-e629-4cfe-3a2d53b20e61
2013-08-25 12:45:36 +00:00
timecop@gmail.com 659a8f537f add support to gcc Makefile to make map file for debugging.
git-svn-id: https://afrodevices.googlecode.com/svn/trunk/baseflight@385 7c89a4a9-59b9-e629-4cfe-3a2d53b20e61
2013-08-24 11:06:34 +00:00
timecop@gmail.com 0664b3005d fixed Makefile to build w/new drivers (thanks Hydra)
int32 updates in sonar driver
added 12mhz buzzer check
Removed debug output from GPS module
int32'ified althold
output HSE MHz+SysClkMHz on debug[3]

git-svn-id: https://afrodevices.googlecode.com/svn/trunk/baseflight@379 7c89a4a9-59b9-e629-4cfe-3a2d53b20e61
2013-08-19 23:29:20 +00:00
timecop@gmail.com 61caceb861 [PATCH 4/4] Make: unbrick target to flash w/ bootloader pins shortened
git-svn-id: https://afrodevices.googlecode.com/svn/trunk/baseflight@333 7c89a4a9-59b9-e629-4cfe-3a2d53b20e61
2013-05-29 00:10:21 +00:00
timecop@gmail.com 96af1bd530 [PATCH 3/4] Add SERIAL_DEVICE to the Makefile for configuring the flash target
git-svn-id: https://afrodevices.googlecode.com/svn/trunk/baseflight@332 7c89a4a9-59b9-e629-4cfe-3a2d53b20e61
2013-05-29 00:09:33 +00:00
timecop@gmail.com 73f599c4e9 [PATCH 1/4] add make target for flashing naze from linux
git-svn-id: https://afrodevices.googlecode.com/svn/trunk/baseflight@330 7c89a4a9-59b9-e629-4cfe-3a2d53b20e61
2013-05-29 00:07:23 +00:00
timecop@gmail.com f2c7ad585a Adding GDB support to the makefile. Use the build option
DEBUG=GDB to have the .elf file contain debugging symbols.

git-svn-id: https://afrodevices.googlecode.com/svn/trunk/baseflight@303 7c89a4a9-59b9-e629-4cfe-3a2d53b20e61
2013-04-09 04:57:42 +00:00
timecop@gmail.com f2a931d248 OLIMEXINO - Initial support for the OLIMEXINO board.
PWM and ADC configuration is the same as the naze32 for now.  Requires an accelerometer is connected via I2C2.
I2C signals SDA2 and SCL2 are on the UEXT header (Pins 6 and 5 respectively)
USART signals TX and RX are on the CON3/CON4 headers (TX = D7, RX = D8)
Onboard LEDs (LED1/LED2) working.
Buzzer support removed for now as it conflicted with PWM map and LEDs.
mma845x support disabled as it conflicted with an LED.
Relocated some NAZE specific comments.

git-svn-id: https://afrodevices.googlecode.com/svn/trunk/baseflight@302 7c89a4a9-59b9-e629-4cfe-3a2d53b20e61
2013-04-07 13:18:37 +00:00
timecop@gmail.com 3cd8e4e3f6 added printf() support via SpareTimeLabs printf lib. this cleaned up some mess inside cli.c
example of usage: http://bcas.tv/paste/results/xToE9w26.html
hover-tested quadx loaded as custom mix, works.

git-svn-id: https://afrodevices.googlecode.com/svn/trunk/baseflight@207 7c89a4a9-59b9-e629-4cfe-3a2d53b20e61
2012-09-06 06:35:02 +00:00
timecop e6cb4a0b1c cleaned up bmp085 driver
added ms5611 driver
refactored pressure sensor subsystem to allow multiple sensors
couple changes in PWM driver to make motor/servo arrangement for airplane mode more intuitive
moved MAX_MOTORS/MAX_SERVOS etc into drv_pwm.h
staring to merge back in airplane/flyingwing mixes
fix for tri servo display - mwc moved it to servo[5] again, gui was broken, function not.
will probably implement custom mixer soon (motors only, no servos)


git-svn-id: https://afrodevices.googlecode.com/svn/trunk/baseflight@198 7c89a4a9-59b9-e629-4cfe-3a2d53b20e61
2012-08-20 10:25:10 +00:00
timecop 9b7e26b274 makefile fix to add l3gd driver
git-svn-id: https://afrodevices.googlecode.com/svn/trunk/baseflight@196 7c89a4a9-59b9-e629-4cfe-3a2d53b20e61
2012-08-15 14:51:17 +00:00
timecop e70d7b5d16 added softi2c source file (oops)
changed gpio speeds to 2mhz from 50, nothing is toggling at 50mhz here. reduce ringing/noise.

git-svn-id: https://afrodevices.googlecode.com/svn/trunk/baseflight@181 7c89a4a9-59b9-e629-4cfe-3a2d53b20e61
2012-07-14 07:43:18 +00:00
timecop 23d11299b8 added test driver for software i2c. disabled by default. no, that wasn't the cause of cycletime jumps.
increased flash size to 128k, moved config data in last kbyte of that. as a result all settings are reset, please save them.
corrected hex6x mixer.
added telemetry to makefile.

git-svn-id: https://afrodevices.googlecode.com/svn/trunk/baseflight@180 7c89a4a9-59b9-e629-4cfe-3a2d53b20e61
2012-07-14 02:00:39 +00:00
timecop ce1ec92a67 Makefile fix from zippe; Untested to build on Win32, but presumably works on Lunix, etc.
Now properly builds both Naze and FY90Q targets.

git-svn-id: https://afrodevices.googlecode.com/svn/trunk/baseflight@167 7c89a4a9-59b9-e629-4cfe-3a2d53b20e61
2012-06-19 05:46:55 +00:00
timecop 8fb580d3f5 added FY90Q buyild target to Makefile
fixed mag calibration finally I think...
heading + mag declination calculation done using better precision.
increased gyro bias calculation to 1000.


git-svn-id: https://afrodevices.googlecode.com/svn/trunk/baseflight@163 7c89a4a9-59b9-e629-4cfe-3a2d53b20e61
2012-06-14 03:35:23 +00:00
timecop 14f87034c7 Makefile fix by g1pete.
now not trying to build stmloader by arm-eabi-gcc.

git-svn-id: https://afrodevices.googlecode.com/svn/trunk/baseflight@139 7c89a4a9-59b9-e629-4cfe-3a2d53b20e61
2012-03-31 06:07:50 +00:00
timecop e92d9e8261 Makefile fixes by IceWind - make building on lunix / mac succeed, and I've tested it works on a real OS as well.
git-svn-id: https://afrodevices.googlecode.com/svn/trunk/baseflight@106 7c89a4a9-59b9-e629-4cfe-3a2d53b20e61
2012-03-06 23:27:12 +00:00
timecop 5091f3e9ff moved source files around in preparation to adding makefile build way
added makefile (thx gke)
added linker script (thx gke)
moved startups into src directory as well
no code changes.

git-svn-id: https://afrodevices.googlecode.com/svn/trunk/baseflight@105 7c89a4a9-59b9-e629-4cfe-3a2d53b20e61
2012-03-06 04:41:23 +00:00