Important changes to repositories hosted on mbed.com
Mbed hosted mercurial repositories are deprecated and are due to be permanently deleted in July 2026.
To keep a copy of this software download the repository Zip archive or clone locally using Mercurial.
It is also possible to export all your personal repositories from the account settings page.
Dependencies: FreescaleIAP mbed-rtos mbed
Fork of workinQM_10thDec by
Diff: BCN.cpp
- Revision:
- 42:413cd8c60cfc
- Parent:
- 39:670133e7ffd8
- Child:
- 43:dec54ff03d3f
--- a/BCN.cpp Tue Jul 05 13:44:15 2016 +0000 +++ b/BCN.cpp Tue Jul 05 18:20:41 2016 +0000 @@ -6,8 +6,9 @@ //Takes max 4 sec in void FCTN_BCN_TX_MAIN() (temp.calc. + long_beacon + short_beacon) Serial pc_bcn(USBTX, USBRX); //tx,rx -SPI spi(D11, D12, D13); // mosi, miso, sclk -DigitalInOut cs(D10); //slave select or chip select +SPI spi(PIN16, PIN17, PIN15); // mosi, miso, sclk +//SPI spi(D11, D12, D13); // mosi, miso, sclk +DigitalOut cs(PIN6); //slave select or chip select //SPI spi(PIN16, PIN17, PIN15); // mosi, miso, sclk //DigitalOut cs(PIN6); //slave select or chip select Timer t_i;//timer for checking the time taken by (temp.calc. + long_beacon + short_beacon) @@ -50,11 +51,21 @@ //1st 0-7 call sign //SHORT_HK_data[0] _ SHORT_HK_data[6] + SHORT_HK_data[0] = 0xF3; + SHORT_HK_data[1] = 0x02; + SHORT_HK_data[2] = 0xFA; + SHORT_HK_data[3] = 0xC6; + SHORT_HK_data[4] = 0xD4; + SHORT_HK_data[5] = 0x28; + SHORT_HK_data[6] = 0x8A; + SHORT_HK_data[7] = quant_data.voltage_quant[15]; SHORT_HK_data[7] = (SHORT_HK_data[7] & 0xF0) | (quant_data.current_quant[1]>>4); + SHORT_HK_data[8] = 0xFF; //braga SHORT_HK_data[8] = acs first 4 bit SHORT_HK_data[8] = (SHORT_HK_data[8] & 0xF0) | BCN_TMP>>4; + SHORT_HK_data[9] = 0xFF; //SHORT_HK_data[9] = float_to_uint8(min,max,EPS_BTRY_TMP_AVG); min max diss azad SHORT_HK_data[9] = (SHORT_HK_data[9]&0xF0) | BAE_RESET_COUNTER>>4;