Fixed messup after last squashed commits

This commit is contained in:
furrtek 2016-12-24 16:54:44 +01:00
parent 6bcb7dc1b1
commit 9470028308
11 changed files with 7 additions and 60 deletions

View File

@ -27,6 +27,8 @@
namespace ui {
// Use firmware/tools/make_bitmap.py !
static constexpr uint8_t bitmap_stealth_data[] = {
0x00, 0x00,
0x00, 0x00,

View File

@ -20,7 +20,7 @@
* Boston, MA 02110-1301, USA.
*/
// Bitmaps generated with:
// Color bitmaps generated with:
// Gimp image > indexed colors (16), then "xxd -i *.bmp"
//TEST: Imperial in whipcalc

View File

@ -82,17 +82,9 @@ void make_4A_group(uint32_t blocks[], const uint16_t PI_code, const bool TP, con
uint32_t L = 0;
uint32_t day_code;
<<<<<<< HEAD
// 57723
if ((month == 1) || (month == 2)) L = 1;
day_code = 14956 + day + (uint32_t)((float)(year - 1900 - L) * 365.25) + uint16_t((float)((month + 1) + L * 12) * 30.6001);
=======
if ((month == 1) || (month == 2)) L = 1;
day_code = 14956 + day + (uint32_t)((float)(year - L) * 365.25) + uint16_t(((month + 1) * L * 12) * 30.6001);
>>>>>>> d402a87... RDS radiotext and time group generators
blocks[0] = PI_code;
blocks[1] = (0x4 << 12) | (0 << 11) | (b2b(TP) << 10) | ((PTY & 0x1F) << 5) | ((day_code & 0x18000) >> 15);
@ -106,11 +98,7 @@ uint16_t gen_PSN(const char * psname, const RDS_flags * rds_flags) {
// 4 groups with 2 PSN characters in each
for (c = 0; c < 4; c++)
<<<<<<< HEAD
make_0B_group(&group[c][0], rds_flags->PI_code, rds_flags->TP, rds_flags->PTY, rds_flags->TA, rds_flags->MS, rds_flags->DI, c, &psname[c * 2]);
=======
make_0B_group(&group[c][0], rds_flags->PI_code, rds_flags->TP, rds_flags->PTY, rds_flags->TA, rds_flags->MS, rds_flags->DI, c, &psname[c * 2]);
>>>>>>> d402a87... RDS radiotext and time group generators
// Generate checkbits for each block of each group
for (c = 0; c < 4; c++) {
@ -187,11 +175,7 @@ uint16_t gen_ClockTime(const RDS_flags * rds_flags,
group[2] = makeblock(group[2], RDS_OFFSET_C);
group[3] = makeblock(group[3], RDS_OFFSET_D);
<<<<<<< HEAD
uint32_t * tx_data_u32 = (uint32_t*)shared_memory.bb_data.data;
=======
uint32_t * tx_data_u32 = (uint32_t*)shared_memory.tx_data;
>>>>>>> d402a87... RDS radiotext and time group generators
// Copy to tx_data for baseband
for (c = 0; c < 4; c++)

View File

@ -37,19 +37,11 @@ namespace rds {
struct RDS_flags {
uint16_t PI_code;
<<<<<<< HEAD
uint8_t PTY;
uint8_t DI;
bool TP;
bool TA;
bool MS;
=======
bool TP;
uint8_t PTY;
bool TA;
bool MS;
bool DI;
>>>>>>> d402a87... RDS radiotext and time group generators
};
uint32_t makeblock(uint32_t blockdata, uint16_t offset);

View File

@ -271,7 +271,7 @@ BHTView::BHTView(NavigationView& nav) {
&header_code_b,
&checkbox_speaker,
&bmp_speaker,
&city_code_xs,
&city_code_xy,
&family_code_xy,
&text_subfamily,
&subfamily_code,

View File

@ -318,7 +318,7 @@ TransmitterAudioMenuView::TransmitterAudioMenuView(NavigationView& nav) {
UtilitiesView::UtilitiesView(NavigationView& nav) {
add_items<3>({ {
{ "Frequency manager", ui::Color::grey(), [&nav](){ nav.push<FreqManView>(); } },
{ "Frequency manager", ui::Color::red(), [&nav](){ nav.push<FreqManView>(); } },
{ "Whip antenna length", ui::Color::green(), [&nav](){ nav.push<WhipCalcView>(); } },
{ "Notepad", ui::Color::grey(), [&nav](){ nav.push<NotImplementedView>(); } },
} });

View File

@ -146,27 +146,15 @@ RDSView::RDSView(NavigationView& nav) {
};
options_coverage.set_selected_index(0); // Local
<<<<<<< HEAD
button_editpsn.on_select = [this, &nav](Button&) {
textentry(nav, PSN, 8);
};
button_tx.on_select = [this](Button&) {
=======
options_pty.on_change = [this](size_t, int32_t v) {
rds_flags.PTY = v;
};
button_editpsn.on_select = [this,&nav](Button&) {
textentry(nav, PSN, 8);
};
button_txpsn.on_select = [this](Button&) {
>>>>>>> d402a87... RDS radiotext and time group generators
if (txing) {
transmitter_model.disable();
button_tx.set_text("START");
txing = false;
} else {
<<<<<<< HEAD
rds_flags.PI_code = sym_pi_code.value_hex_u64();
rds_flags.PTY = options_pty.selected_index_value();
rds_flags.DI = check_mono_stereo.value() ? 1 : 0;
@ -182,10 +170,7 @@ RDSView::RDSView(NavigationView& nav) {
message_length = gen_ClockTime(&rds_flags, 2016, 12, 1, 9, 23, 2);
button_tx.set_text("STOP");
=======
message_length = gen_PSN(PSN, &rds_flags);
button_txpsn.set_text("STOP");
>>>>>>> d402a87... RDS radiotext and time group generators
txing = true;
start_tx();
}
@ -194,22 +179,6 @@ RDSView::RDSView(NavigationView& nav) {
button_editradiotext.on_select = [this, &nav](Button&){
textentry(nav, RadioText, 24);
};
<<<<<<< HEAD
=======
button_txradiotext.on_select = [this](Button&){
if (txing) {
button_txpsn.set_text("PSN");
button_txradiotext.set_text("Radiotext");
transmitter_model.disable();
txing = false;
} else {
message_length = gen_RadioText(RadioText, 0, &rds_flags);
button_txradiotext.set_text("STOP");
txing = true;
start_tx();
}
};
>>>>>>> d402a87... RDS radiotext and time group generators
button_exit.on_select = [&nav](Button&){
nav.pop();

Binary file not shown.

Binary file not shown.

Binary file not shown.

Binary file not shown.