apps/agl-service-can-low-level.git
10 years agoInclude platform name in also the directory name in binary pkgs
Petteri Aimonen [Sun, 29 Dec 2013 18:25:36 +0000 (20:25 +0200)]
Include platform name in also the directory name in binary pkgs

10 years agoAdd packaging script for Mac, add platform name to packages.
Petteri Aimonen [Tue, 3 Dec 2013 18:35:29 +0000 (20:35 +0200)]
Add packaging script for Mac, add platform name to packages.

10 years agoFixes for pyinstaller
Petteri Aimonen [Tue, 3 Dec 2013 18:10:48 +0000 (20:10 +0200)]
Fixes for pyinstaller

10 years agoSmall fix for previous
Petteri Aimonen [Tue, 3 Dec 2013 17:30:39 +0000 (19:30 +0200)]
Small fix for previous

10 years agoCheck for supported GCC CCFLAGS when building tests.
Petteri Aimonen [Tue, 3 Dec 2013 17:27:08 +0000 (19:27 +0200)]
Check for supported GCC CCFLAGS when building tests.

10 years agoMake generator print errors to stderr.
Petteri Aimonen [Tue, 3 Dec 2013 16:44:25 +0000 (18:44 +0200)]
Make generator print errors to stderr.

Otherwise they won't be visible when run as a protoc plugin.

10 years agoAdd a SCons tool for nanopb protos.
Petteri Aimonen [Sat, 23 Nov 2013 09:04:12 +0000 (11:04 +0200)]
Add a SCons tool for nanopb protos.

This tool script is useful both for building the tests and also for use in other applications.

10 years agoFix protoc-gen-nanopb in linux package
Petteri Aimonen [Sun, 17 Nov 2013 20:37:48 +0000 (22:37 +0200)]
Fix protoc-gen-nanopb in linux package

10 years agoInclude libprotoc
Petteri Aimonen [Sun, 17 Nov 2013 20:33:26 +0000 (22:33 +0200)]
Include libprotoc

10 years agoLinux archive
Petteri Aimonen [Sun, 17 Nov 2013 20:25:52 +0000 (22:25 +0200)]
Linux archive

10 years agoAlso include the manifest for MSVCR90.DLL
Petteri Aimonen [Sun, 17 Nov 2013 20:19:54 +0000 (22:19 +0200)]
Also include the manifest for MSVCR90.DLL

10 years agoInclude MSVCR90.DLL also.
Petteri Aimonen [Sun, 17 Nov 2013 19:43:50 +0000 (21:43 +0200)]
Include MSVCR90.DLL also.

10 years agoInclude Visual C++ runtime in the Windows package.
Petteri Aimonen [Sun, 17 Nov 2013 19:20:12 +0000 (21:20 +0200)]
Include Visual C++ runtime in the Windows package.

10 years agoREADME updates
Petteri Aimonen [Sun, 17 Nov 2013 18:57:50 +0000 (20:57 +0200)]
README updates

10 years agoWindows build fixes
Petteri Aimonen [Sun, 17 Nov 2013 18:37:18 +0000 (20:37 +0200)]
Windows build fixes

10 years agoFix protoc plugin path
Petteri Aimonen [Sun, 17 Nov 2013 18:25:18 +0000 (20:25 +0200)]
Fix protoc plugin path

10 years agoActually no, it was a portability hassle
Petteri Aimonen [Sun, 17 Nov 2013 18:24:32 +0000 (20:24 +0200)]
Actually no, it was a portability hassle

10 years agoMakefile tuning
Petteri Aimonen [Sun, 17 Nov 2013 18:09:30 +0000 (20:09 +0200)]
Makefile tuning

10 years agoRework the Makefiles to be compatible with binary packages.
Petteri Aimonen [Sun, 17 Nov 2013 18:04:29 +0000 (20:04 +0200)]
Rework the Makefiles to be compatible with binary packages.

10 years agoMoving files around
Petteri Aimonen [Sun, 17 Nov 2013 17:20:04 +0000 (19:20 +0200)]
Moving files around

Renamed READMEs to README.txt to be more friendly for Windows users.

10 years agoPackage as .zip, convert linebreaks
Petteri Aimonen [Sun, 17 Nov 2013 17:09:13 +0000 (19:09 +0200)]
Package as .zip, convert linebreaks

10 years agoAdd build script for windows package
Petteri Aimonen [Sun, 17 Nov 2013 15:37:29 +0000 (17:37 +0200)]
Add build script for windows package

10 years agoAdd descriptor.proto to repository to avoid messing with protoc include path.
Petteri Aimonen [Sun, 17 Nov 2013 14:42:52 +0000 (16:42 +0200)]
Add descriptor.proto to repository to avoid messing with protoc include path.

10 years agoAdd script for making linux binary package
Petteri Aimonen [Sun, 17 Nov 2013 13:46:41 +0000 (15:46 +0200)]
Add script for making linux binary package

10 years agoMove the generator .proto files to a subdir, and get rid of precompiled versions.
Petteri Aimonen [Sun, 17 Nov 2013 13:07:12 +0000 (15:07 +0200)]
Move the generator .proto files to a subdir, and get rid of precompiled versions.

10 years agoBring alltypes_pointer testcase up to date
Petteri Aimonen [Sun, 29 Dec 2013 16:44:58 +0000 (18:44 +0200)]
Bring alltypes_pointer testcase up to date

10 years agoImprove alltypes_pointer test case
Petteri Aimonen [Sun, 29 Dec 2013 16:35:14 +0000 (18:35 +0200)]
Improve alltypes_pointer test case

10 years agoFix missing error messages in pb_encode.c
Petteri Aimonen [Sun, 29 Dec 2013 16:34:57 +0000 (18:34 +0200)]
Fix missing error messages in pb_encode.c

10 years agoRename encode_static_field -> encode_basic_field.
Petteri Aimonen [Mon, 9 Dec 2013 17:25:19 +0000 (19:25 +0200)]
Rename encode_static_field -> encode_basic_field.

10 years agoOrganize allocation logic in generator, add pb_bytes_ptr_t.
Petteri Aimonen [Mon, 9 Dec 2013 17:19:12 +0000 (19:19 +0200)]
Organize allocation logic in generator, add pb_bytes_ptr_t.

Allocation decision is now made before the field data type is decided.
This way the data type decisions can more cleanly account for the allocation
type, i.e. FT_DEFAULT logic etc.

Added pb_bytes_ptr_t for pointer-allocated bytes-fields. There is no point
generating separate structs for these, as they would all be of the same type.

10 years agoConst-correctness and small cleanup.
Petteri Aimonen [Mon, 9 Dec 2013 17:15:26 +0000 (19:15 +0200)]
Const-correctness and small cleanup.

10 years agoGenerating and encoding messages with dynamic allocaiton
Martin Donath [Sun, 8 Dec 2013 22:25:32 +0000 (23:25 +0100)]
Generating and encoding messages with dynamic allocaiton

10 years agoNegative int32 values take 10 bytes now.
Petteri Aimonen [Sun, 22 Dec 2013 21:24:02 +0000 (23:24 +0200)]
Negative int32 values take 10 bytes now.

10 years agoFix problem with decode_legacy test case on Windows.
Petteri Aimonen [Sat, 21 Dec 2013 16:08:04 +0000 (18:08 +0200)]
Fix problem with decode_legacy test case on Windows.

10 years agoAdd test for extreme integer values (INT32_MAX etc.) in AllTypes.
Petteri Aimonen [Sat, 21 Dec 2013 10:41:20 +0000 (12:41 +0200)]
Add test for extreme integer values (INT32_MAX etc.) in AllTypes.

10 years agoAdd PB_LTYPE_UVARINT to fix encoding of negative int32 values.
Petteri Aimonen [Sat, 21 Dec 2013 10:16:03 +0000 (12:16 +0200)]
Add PB_LTYPE_UVARINT to fix encoding of negative int32 values.

Apparently int32 values that are negative must be cast into int64 first
before being encoded. Because uint32 still needs to be cast to uint64,
the cases for int32 and uint32 had to be separated.

Update issue 97
Status: FixedInGit

10 years agoModify the alltypes test to check re-encoding through protoc.
Petteri Aimonen [Sat, 21 Dec 2013 10:14:20 +0000 (12:14 +0200)]
Modify the alltypes test to check re-encoding through protoc.

This way we can verify that the message is encoded exactly the same way
as the official protobuf implementation would do it.

11 years agoOptimize the common case of 1-byte reads for varints.
Petteri Aimonen [Thu, 14 Nov 2013 15:56:42 +0000 (17:56 +0200)]
Optimize the common case of 1-byte reads for varints.

For PB_BUFFER_ONLY configuration, this gives 20% speedup without
increasing code size.

11 years agoMake tests build in a separate folder, add to gitignore
Petteri Aimonen [Wed, 13 Nov 2013 20:10:42 +0000 (22:10 +0200)]
Make tests build in a separate folder, add to gitignore

11 years agoFix path in FindNanopb.cmake.
Petteri Aimonen [Mon, 11 Nov 2013 07:22:32 +0000 (09:22 +0200)]
Fix path in FindNanopb.cmake.

Update issue 94
Status: FixedInGit

11 years agoSetting version to 0.2.5-dev
Petteri Aimonen [Thu, 7 Nov 2013 14:47:14 +0000 (16:47 +0200)]
Setting version to 0.2.5-dev

11 years agoPublishing nanopb-0.2.4
Petteri Aimonen [Thu, 7 Nov 2013 14:44:41 +0000 (16:44 +0200)]
Publishing nanopb-0.2.4

11 years agoAdd dates to changelog
Petteri Aimonen [Sat, 2 Nov 2013 20:19:26 +0000 (22:19 +0200)]
Add dates to changelog

11 years agoUpdate changelog
Petteri Aimonen [Sat, 2 Nov 2013 20:11:27 +0000 (22:11 +0200)]
Update changelog

11 years agoGenerate #define tags for extension fields also.
Petteri Aimonen [Sat, 2 Nov 2013 20:05:49 +0000 (22:05 +0200)]
Generate #define tags for extension fields also.

Update issue 93
Status: FixedInGit

11 years agoRemove the NANOPB_INTERNALS functions from public API.
Petteri Aimonen [Tue, 29 Oct 2013 14:32:47 +0000 (16:32 +0200)]
Remove the NANOPB_INTERNALS functions from public API.

These have been deprecated since nanopb-0.1.6 (some since 0.1.3).
Equivalent functions with better interface are available in the API.

Update issue 91
Status: FixedInGit

11 years agoDeclare static functions before use.
Petteri Aimonen [Tue, 29 Oct 2013 14:24:50 +0000 (16:24 +0200)]
Declare static functions before use.

For compliance with MISRA C rules (issue 91).

11 years agoCleanup of comments.
Petteri Aimonen [Tue, 29 Oct 2013 14:19:07 +0000 (16:19 +0200)]
Cleanup of comments.

11 years agoAdd a definition of the security model to the documentation.
Petteri Aimonen [Tue, 29 Oct 2013 13:44:35 +0000 (15:44 +0200)]
Add a definition of the security model to the documentation.

11 years agoRename some internal functions to have unique names
Petteri Aimonen [Tue, 29 Oct 2013 13:32:51 +0000 (15:32 +0200)]
Rename some internal functions to have unique names

11 years agoDetect invalid sizes when encoding bytes fields.
Petteri Aimonen [Thu, 24 Oct 2013 18:45:39 +0000 (21:45 +0300)]
Detect invalid sizes when encoding bytes fields.

11 years agoSame fix for EncodedSize.__mul__
Petteri Aimonen [Thu, 24 Oct 2013 06:52:40 +0000 (09:52 +0300)]
Same fix for EncodedSize.__mul__

11 years agoHandle also longs in EncodedSize
Petteri Aimonen [Thu, 24 Oct 2013 05:44:59 +0000 (08:44 +0300)]
Handle also longs in EncodedSize

11 years agoFix the size of length prefix for messages in other files.
Petteri Aimonen [Wed, 23 Oct 2013 18:21:43 +0000 (21:21 +0300)]
Fix the size of length prefix for messages in other files.

11 years agoGenerate message size #defines also for messages defined in multiple files.
Petteri Aimonen [Wed, 23 Oct 2013 18:01:11 +0000 (21:01 +0300)]
Generate message size #defines also for messages defined in multiple files.

Add testcase for the same.

11 years agoDefine pb_size_t and pb_ssize_t data types.
Petteri Aimonen [Sun, 20 Oct 2013 18:49:55 +0000 (21:49 +0300)]
Define pb_size_t and pb_ssize_t data types.

Use these in pb_field_t definition to clean up some #ifs, and also
to prepare for solving issue #82.

11 years agoCheck array max size when encoding.
Petteri Aimonen [Sun, 20 Oct 2013 18:42:00 +0000 (21:42 +0300)]
Check array max size when encoding.

Update issue 90
Status: FixedInGit

11 years agoAdd #defines for the maximum encoded message size.
Petteri Aimonen [Thu, 26 Sep 2013 07:23:37 +0000 (10:23 +0300)]
Add #defines for the maximum encoded message size.

Update issue 89
Status: FixedInGit

11 years agoSetting version to 0.2.4-dev
Petteri Aimonen [Wed, 18 Sep 2013 09:47:32 +0000 (12:47 +0300)]
Setting version to 0.2.4-dev

11 years agoPublishing nanopb-0.2.3
Petteri Aimonen [Wed, 18 Sep 2013 09:44:46 +0000 (12:44 +0300)]
Publishing nanopb-0.2.3

11 years agoUpdate changelog
Petteri Aimonen [Fri, 13 Sep 2013 10:41:57 +0000 (13:41 +0300)]
Update changelog

11 years agoAdd a new very simple example
Petteri Aimonen [Fri, 13 Sep 2013 10:35:25 +0000 (13:35 +0300)]
Add a new very simple example

11 years agoMove examples into subfolders, add READMEs
Petteri Aimonen [Fri, 13 Sep 2013 09:59:31 +0000 (12:59 +0300)]
Move examples into subfolders, add READMEs

11 years agoMerge branch 'dev_get_rid_of_ternary_operator'
Petteri Aimonen [Fri, 13 Sep 2013 08:31:45 +0000 (11:31 +0300)]
Merge branch 'dev_get_rid_of_ternary_operator'

11 years agoFine-tune the naming of new macros before merging into master.
Petteri Aimonen [Fri, 13 Sep 2013 08:30:58 +0000 (11:30 +0300)]
Fine-tune the naming of new macros before merging into 

Requires re-generation of files generated with dev_get_rid_of_ternary_operator.

11 years agoExpand extra_fields test to cover field skipping in case of streams.
Petteri Aimonen [Wed, 11 Sep 2013 14:33:50 +0000 (17:33 +0300)]
Expand extra_fields test to cover field skipping in case of streams.

11 years agoDisable warning about uint64_t (long long)
Petteri Aimonen [Wed, 11 Sep 2013 13:51:53 +0000 (16:51 +0300)]
Disable warning about uint64_t (long long)

11 years agoFix build error when path contains spaces
Petteri Aimonen [Wed, 11 Sep 2013 13:45:52 +0000 (16:45 +0300)]
Fix build error when path contains spaces

11 years agoMerge branch 'dev_tests_using_scons'
Petteri Aimonen [Wed, 11 Sep 2013 13:13:19 +0000 (16:13 +0300)]
Merge branch 'dev_tests_using_scons'

11 years agoAdd tests for different compilation options
Petteri Aimonen [Wed, 11 Sep 2013 11:55:56 +0000 (14:55 +0300)]
Add tests for different compilation options

11 years agoWindows build fixes
Petteri Aimonen [Wed, 11 Sep 2013 10:42:56 +0000 (13:42 +0300)]
Windows build fixes

11 years agoMake all the tests ANSI C compatible.
Petteri Aimonen [Wed, 11 Sep 2013 10:16:20 +0000 (13:16 +0300)]
Make all the tests ANSI C compatible.

11 years agoGet rid of the ternary operator in the pb_field_t initialization.
Petteri Aimonen [Wed, 11 Sep 2013 06:53:51 +0000 (09:53 +0300)]
Get rid of the ternary operator in the pb_field_t initialization.

Some compilers where unable to detect that the ternary operator
can be evaluated at the compile time. This commit does the evaluation
on the Python side, which should fix the problem.

The new .pb.c files are generated using PB_FIELD2() macro. The old
PB_FIELD() macro remains, so that previously generated files keep
working.

11 years agoMove the rest of the tests to scons
Petteri Aimonen [Tue, 10 Sep 2013 19:34:54 +0000 (22:34 +0300)]
Move the rest of the tests to scons

11 years agoCompiler options for GCC, clang and tcc
Petteri Aimonen [Tue, 10 Sep 2013 17:54:29 +0000 (20:54 +0300)]
Compiler options for GCC, clang and tcc

11 years agoMove the declarations of _pb_ostream_t and _pb_istream_t before first use.
Petteri Aimonen [Mon, 9 Sep 2013 07:53:04 +0000 (10:53 +0300)]
Move the declarations of _pb_ostream_t and _pb_istream_t before first use.

Otherwise Microsoft Visual C++ threats them as C++ classes instead of plain
structs, forbidding use in C linkage functions.

Thanks to Markus Schwarzenberg for the patch.

Update issue 84
Status: Started

11 years agoBuild fixes for Windows/Visual C++
Petteri Aimonen [Tue, 10 Sep 2013 14:44:32 +0000 (17:44 +0300)]
Build fixes for Windows/Visual C++

11 years agoAdd an example pb_syshdr.h file for platforms without C99.
Petteri Aimonen [Tue, 10 Sep 2013 09:39:39 +0000 (12:39 +0300)]
Add an example pb_syshdr.h file for platforms without C99.

This allows building the tests easily on Visual C++ in C mode.

Also add checks to pb.h that the defined integer types are of
the proper sizes. This may prevent some difficult to debug problems
later..

11 years agoConvert more test cases to scons
Petteri Aimonen [Tue, 10 Sep 2013 08:34:57 +0000 (11:34 +0300)]
Convert more test cases to scons

11 years agoMove the declarations of _pb_ostream_t and _pb_istream_t before first use.
Petteri Aimonen [Mon, 9 Sep 2013 07:53:04 +0000 (10:53 +0300)]
Move the declarations of _pb_ostream_t and _pb_istream_t before first use.

Otherwise Microsoft Visual C++ threats them as C++ classes instead of plain
structs, forbidding use in C linkage functions.

Thanks to Markus Schwarzenberg for the patch.

Update issue 84
Status: Started

11 years agoAdd support for running the nanopb generator as protoc plugin.
Petteri Aimonen [Sun, 8 Sep 2013 16:55:05 +0000 (19:55 +0300)]
Add support for running the nanopb generator as protoc plugin.

Will be used to implement issue 47.

For now, symlink nanopb_generator.py as protoc-gen-nanopb and
use protoc --nanopb_out=. to call it.

11 years agoStart moving the tests into subfolders. Transition to SCons for build system for...
Petteri Aimonen [Sun, 8 Sep 2013 14:52:03 +0000 (17:52 +0300)]
Start moving the tests into subfolders. Transition to SCons for build system for the tests.

Only a few tests updated so far. Have to include all the rest before merging to mainline.

Update issue 63
Status: Started

11 years agoHandle unsupported extension field types more gracefully.
Petteri Aimonen [Sun, 8 Sep 2013 08:05:20 +0000 (11:05 +0300)]
Handle unsupported extension field types more gracefully.

Previously the generator would stop with NotImplementedException as
soon as a required or repeated extension field is found. New behaviour
is to just ignore the unsupported field and note that in a comment
in the generated file.

Furthermore, allow skipping of extension fields using the generator
option (nanopb).type = FT_IGNORE.

Update issue 83
Status: FixedInGit

11 years agoSetting version to 0.2.3-dev
Petteri Aimonen [Sun, 18 Aug 2013 19:12:31 +0000 (22:12 +0300)]
Setting version to 0.2.3-dev

11 years agoPublishing nanopb-0.2.2
Petteri Aimonen [Sun, 18 Aug 2013 19:11:38 +0000 (22:11 +0300)]
Publishing nanopb-0.2.2

11 years agoUpdate changelog
Petteri Aimonen [Thu, 8 Aug 2013 17:45:30 +0000 (20:45 +0300)]
Update changelog

11 years agoDocument field extensions support
Petteri Aimonen [Thu, 8 Aug 2013 17:37:59 +0000 (20:37 +0300)]
Document field extensions support

Update issue 17
Status: FixedInGit

11 years agoDocument PB_SYSTEM_HEADER
Petteri Aimonen [Thu, 8 Aug 2013 17:05:30 +0000 (20:05 +0300)]
Document PB_SYSTEM_HEADER

11 years agoFinish the testcase for extensions
Petteri Aimonen [Mon, 22 Jul 2013 16:00:04 +0000 (19:00 +0300)]
Finish the testcase for extensions

11 years agoFix bugs in extension support when multiple extension fields are present.
Petteri Aimonen [Mon, 22 Jul 2013 15:59:15 +0000 (18:59 +0300)]
Fix bugs in extension support when multiple extension fields are present.

11 years agoExtension support implemented for decoder.
Petteri Aimonen [Wed, 17 Jul 2013 17:21:51 +0000 (20:21 +0300)]
Extension support implemented for decoder.

Testing is still needed. Also only 'optional' extension fields
are supported now, 'repeated' fields are not yet supported.

11 years agoAdd test case for extensions decoding
Petteri Aimonen [Wed, 17 Jul 2013 16:29:06 +0000 (19:29 +0300)]
Add test case for extensions decoding

11 years agoImplement extension support for the encoder
Petteri Aimonen [Wed, 17 Jul 2013 16:23:19 +0000 (19:23 +0300)]
Implement extension support for the encoder

11 years agoImplement generator support for extension fields (no encoder/decoder support yet)
Petteri Aimonen [Tue, 16 Jul 2013 21:06:54 +0000 (00:06 +0300)]
Implement generator support for extension fields (no encoder/decoder support yet)

11 years agoFix formatting in documentation
Petteri Aimonen [Tue, 16 Jul 2013 08:31:38 +0000 (11:31 +0300)]
Fix formatting in documentation

11 years agoCheck for empty message type before incrementing required_field_index.
Kent Ryhorchuk [Tue, 16 Jul 2013 01:04:47 +0000 (18:04 -0700)]
Check for empty message type before incrementing required_field_index.

If you have a message that defined as empty, but attempt to decode a
message that has one or more unknown fields then pb_decode fails. The
method used to count the number of required fields counts 1 required
field because the default type of PB_LAST_FIELD is PB_HTYPE_REQUIRED.

11 years agoAdd test case for extra fields in AllTypes
Petteri Aimonen [Tue, 16 Jul 2013 08:07:34 +0000 (11:07 +0300)]
Add test case for extra fields in AllTypes

11 years agoAdd pb_decode_delimited and pb_encode_delimited wrapper functions.
Petteri Aimonen [Sat, 6 Jul 2013 13:16:00 +0000 (16:16 +0300)]
Add pb_decode_delimited and pb_encode_delimited wrapper functions.

Update issue 74
Status: FixedInGit

11 years agoClean up the comments in pb_encode.h and pb_decode.h
Petteri Aimonen [Sat, 6 Jul 2013 12:55:15 +0000 (15:55 +0300)]
Clean up the comments in pb_encode.h and pb_decode.h

11 years agoAdd section in pb.h for changing compilation settings.
Petteri Aimonen [Sat, 6 Jul 2013 12:27:31 +0000 (15:27 +0300)]
Add section in pb.h for changing compilation settings.

Update issue 76
Status: FixedInGit