Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion tools/pioasm/c_sdk_output.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -109,7 +109,7 @@ struct c_sdk_output : public output_format {
fprintf(out, " .instructions = %sprogram_instructions,\n", prefix.c_str());
fprintf(out, " .length = %d,\n", (int) program.instructions.size());
fprintf(out, " .origin = %d,\n", program.origin.get());
fprintf(out, " .pio_version = %d,\n", program.pio_version);
fprintf(out, " .pio_version = %spio_version,\n", prefix.c_str());
fprintf(out, "#if PICO_PIO_VERSION > 0\n");
fprintf(out, " .used_gpio_ranges = 0x%x\n", program.used_gpio_ranges);
fprintf(out, "#endif\n");
Expand Down
4 changes: 2 additions & 2 deletions tools/pioasm/gen/parser.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -1127,15 +1127,15 @@ namespace yy {
break;

case 22: // directive: ".in" value direction autop threshold
{ pioasm.get_current_program(yystack_[4].location, ".out", true).set_in(yylhs.location, yystack_[3].value.as < std::shared_ptr<resolvable> > (), yystack_[2].value.as < bool > (), yystack_[1].value.as < bool > (), yystack_[0].value.as < std::shared_ptr<resolvable> > ()); }
{ pioasm.get_current_program(yystack_[4].location, ".in", true).set_in(yylhs.location, yystack_[3].value.as < std::shared_ptr<resolvable> > (), yystack_[2].value.as < bool > (), yystack_[1].value.as < bool > (), yystack_[0].value.as < std::shared_ptr<resolvable> > ()); }
break;

case 23: // directive: ".out" value direction autop threshold
{ pioasm.get_current_program(yystack_[4].location, ".out", true).set_out(yylhs.location, yystack_[3].value.as < std::shared_ptr<resolvable> > (), yystack_[2].value.as < bool > (), yystack_[1].value.as < bool > (), yystack_[0].value.as < std::shared_ptr<resolvable> > ()); }
break;

case 24: // directive: ".set" value
{ pioasm.check_version(1, yylhs.location, ".in"); pioasm.get_current_program(yystack_[1].location, ".out", true).set_set_count(yylhs.location, yystack_[0].value.as < std::shared_ptr<resolvable> > ()); }
{ pioasm.get_current_program(yystack_[1].location, ".set", true).set_set_count(yylhs.location, yystack_[0].value.as < std::shared_ptr<resolvable> > ()); }
break;

case 25: // directive: ".wrap_target"
Expand Down
4 changes: 2 additions & 2 deletions tools/pioasm/parser.yy
Original file line number Diff line number Diff line change
Expand Up @@ -199,9 +199,9 @@ directive:
| SIDE_SET value OPTIONAL { pioasm.get_current_program(@1, ".side_set", true).set_sideset(@$, $2, true, false); }
| SIDE_SET value PINDIRS { pioasm.get_current_program(@1, ".side_set", true).set_sideset(@$, $2, false, true); }
| SIDE_SET value { pioasm.get_current_program(@1, ".side_set", true).set_sideset(@$, $2, false, false); }
| DOT_IN value direction autop threshold { pioasm.get_current_program(@1, ".out", true).set_in(@$, $2, $3, $4, $5); }
| DOT_IN value direction autop threshold { pioasm.get_current_program(@1, ".in", true).set_in(@$, $2, $3, $4, $5); }
| DOT_OUT value direction autop threshold { pioasm.get_current_program(@1, ".out", true).set_out(@$, $2, $3, $4, $5); }
| DOT_SET value { pioasm.check_version(1, @$, ".in"); pioasm.get_current_program(@1, ".out", true).set_set_count(@$, $2); }
| DOT_SET value { pioasm.get_current_program(@1, ".set", true).set_set_count(@$, $2); }
| WRAP_TARGET { pioasm.get_current_program(@1, ".wrap_target").set_wrap_target(@$); }
| WRAP { pioasm.get_current_program(@1, ".wrap").set_wrap(@$); }
| WORD value { pioasm.get_current_program(@1, "instruction").add_instruction(std::shared_ptr<instruction>(new instr_word(@$, $2))); }
Expand Down
Loading