Please login or register.

Login with username, password and session length

News:

Registration is only required if you want to post, and is not needed to read any posts. To avoid excess 'spam' accounts, all accounts where no posts have been made will be deleted after two weeks. Please register again if you wish to post.

Show Posts

This section allows you to view all posts made by this member. Note that you can only see posts made in areas you currently have access to.


Topics - elir71

Pages: [1]
1
Environment models / Snapshot of something I'm working on
« on: January 04, 2023, 06:05:34 PM »
working on a world model of menai straits

2
Models / Under Bridge
« on: August 18, 2022, 07:40:20 AM »
When my own ship tries to pass under a (my own) bridge, it bounces off it instead of passing under it

It is almost certainly a modelling problem

Has anyone any pointers on how to remediate this ?

3
Scenarios / Scenarios wrapping everything up
« on: August 12, 2022, 04:48:12 PM »
Is it possible to add as subfolders, models and worlds which are particular to a scenario, and if so what is the directory structure ?

My new scenario
 |
 --- World --------+----- Humber Estuary
 |                        |
 |                        |
 |                       + ------ Dover Straits
 |
 | ---- Models ---+ ----- Buoy
                         |
                         + ----- LandObject
                         |
                         + ----- Othership
                         |
                         + ----- Ownship
 


4
Development / Compiling Linux Fedora 34
« on: November 16, 2020, 11:33:12 AM »
Can anyone give me some pointers on how to get out of this  :---



Performing C SOURCE FILE Test CMAKE_HAVE_LIBC_PTHREAD failed with the following output:
Change Dir: /home/davide/Projects/bc/CMakeFiles/CMakeTmp

Run Build Command(s):/usr/bin/gmake cmTC_89258/fast && /usr/bin/gmake  -f CMakeFiles/cmTC_89258.dir/build.make CMakeFiles/cmTC_89258.dir/build
gmake[1]: Entering directory '/home/davide/Projects/bc/CMakeFiles/CMakeTmp'
Building C object CMakeFiles/cmTC_89258.dir/src.c.o
/usr/bin/cc   -DCMAKE_HAVE_LIBC_PTHREAD   -o CMakeFiles/cmTC_89258.dir/src.c.o   -c /home/davide/Projects/bc/CMakeFiles/CMakeTmp/src.c
Linking C executable cmTC_89258
/usr/bin/cmake -E cmake_link_script CMakeFiles/cmTC_89258.dir/link.txt --verbose=1
/usr/bin/cc  -DCMAKE_HAVE_LIBC_PTHREAD    -rdynamic CMakeFiles/cmTC_89258.dir/src.c.o  -o cmTC_89258
/usr/bin/ld: CMakeFiles/cmTC_89258.dir/src.c.o: in function `main':
src.c:(.text+0x2d): undefined reference to `pthread_create'
/usr/bin/ld: src.c:(.text+0x39): undefined reference to `pthread_detach'
/usr/bin/ld: src.c:(.text+0x45): undefined reference to `pthread_cancel'
/usr/bin/ld: src.c:(.text+0x56): undefined reference to `pthread_join'
collect2: error: ld returned 1 exit status
gmake[1]: *** [CMakeFiles/cmTC_89258.dir/build.make:107: cmTC_89258] Error 1
gmake[1]: Leaving directory '/home/davide/Projects/bc/CMakeFiles/CMakeTmp'
gmake: *** [Makefile:141: cmTC_89258/fast] Error 2


Source file was:
#include <pthread.h>

void* test_func(void* data)
{
  return data;
}

int main(void)
{
  pthread_t thread;
  pthread_create(&thread, NULL, test_func, NULL);
  pthread_detach(thread);
  pthread_cancel(thread);
  pthread_join(thread, NULL);
  pthread_atfork(NULL, NULL, NULL);
  pthread_exit(NULL);

  return 0;
}

Determining if the function pthread_create exists in the pthreads failed with the following output:
Change Dir: /home/davide/Projects/bc/CMakeFiles/CMakeTmp

Run Build Command(s):/usr/bin/gmake cmTC_2f8c7/fast && /usr/bin/gmake  -f CMakeFiles/cmTC_2f8c7.dir/build.make CMakeFiles/cmTC_2f8c7.dir/build
gmake[1]: Entering directory '/home/davide/Projects/bc/CMakeFiles/CMakeTmp'
Building C object CMakeFiles/cmTC_2f8c7.dir/CheckFunctionExists.c.o
/usr/bin/cc   -DCHECK_FUNCTION_EXISTS=pthread_create   -o CMakeFiles/cmTC_2f8c7.dir/CheckFunctionExists.c.o   -c /usr/share/cmake/Modules/CheckFunctionExists.c
Linking C executable cmTC_2f8c7
/usr/bin/cmake -E cmake_link_script CMakeFiles/cmTC_2f8c7.dir/link.txt --verbose=1
/usr/bin/cc  -DCHECK_FUNCTION_EXISTS=pthread_create    CMakeFiles/cmTC_2f8c7.dir/CheckFunctionExists.c.o  -o cmTC_2f8c7  -lpthreads
/usr/bin/ld: cannot find -lpthreads
collect2: error: ld returned 1 exit status
gmake[1]: *** [CMakeFiles/cmTC_2f8c7.dir/build.make:107: cmTC_2f8c7] Error 1
gmake[1]: Leaving directory '/home/davide/Projects/bc/CMakeFiles/CMakeTmp'
gmake: *** [Makefile:141: cmTC_2f8c7/fast] Error 2



5
Models / models file formats for irrlicht
« on: February 15, 2020, 06:21:04 PM »
is it only .x files that are acceptable as model file format or are there others ? 

6
Bridge Command General Support / Linux Fedora 31 Successful Install
« on: January 01, 2020, 12:05:36 PM »
Most of this are taken from the "how to compile on mac or linux" which is within the source code
However the procedure is slightly different on the Fedora 31 distribution which I just installed on a second hand Dell Optiplex 780
On my equally antique laptop I get 3 to 6 frames per second on my windows 7 whereas on the fedora 28 boot on the same hardware then I am getting 26 fps

I used gitg to obtain the source code
https://github.com/bridgecommand/bc
This saved to my HOME_DIRECTORY/bc

To build on linux:
==================

1) Ensure the required library packages are installed with the following command in the terminal window:
Code: [Select]

sudo yum install mesa_libGL-devel libXxf86vm-devel freeglut-devel libXext-devel libXcursor-devel make g++



If you want sound support then do the steps at the end of this ...

In terminal screen and in the bc directory
Code: [Select]
make to compile Bridge Command

In terminal screen and in the bc directory
Code: [Select]
./bridgecommand to start the simulator.
Additional steps to compile with sound (for both Mac and Linux):
================================================================
Libsndfile:
Download and uncompress libsndfile-1.0.28.tar.gz from http://www.mega-nerd.com/libsndfile/files/libsndfile-1.0.28.tar.gz
Create a folder for the output, referred to as <Somewhere> (Absolute path)
Change directory to where you've uncompressed libsndfile, then run the following in the terminal window:

./configure --disable-shared --prefix=<Somewhere>
make
make install
cd <Somewhere>
cp -a lib <BridgeCommandSourceLocation>/libs/libsndfile/


Portaudio

Download and uncompress pa_stable_v190600_20161030.tgz from
Code: [Select]
http://www.portaudio.com/archives/pa_stable_v190600_20161030.tgzChange directory to where you've uncompressed Portaudio, then run the following in the terminal window:

./configure --disable-shared --enable-static
make
cd lib/.libs/
cp * <BridgeCommandSourceLocation>/libs/portaudio/lib/

Building Bridge Command with sound:
Change to where you have the Bridge Command source then run the following in the terminal window:

make -f MakefileWithSound

7
Models / Azimuth drives - own ship
« on: August 11, 2019, 12:36:44 PM »
I'm experimenting with this at the moment.  It will involve a fair amount of code rewrite but should be useable as a data structure for more flexibility of control surfaces

8
I'm new to using git so please bear with me

I have (tried to) send some ammendments via a fork and pull request

I have not compiled under windows,  I have compiled under linux however I have not uploaded the executables

The ammendment I have made for your consideration and incorporation are as follows :-


1. Softcode the roll period

 as it is primarly a function of the stability condition of the vessel so in the models/ownship.boat.ini there is a new parameter of

rollPeriod=6

denoting a roll period of 6 seconds.  this parameter can be altered to suit the vessel,   Something like a car carrier would typicall be 12 sec.  future plans for this is to softcode pitch period too and to try and model a propensity for synchronous and parametric rolling which is basically a rapid increase in the amplitude of the roll due to resonance between the natural roll period of the vessel and the wave encouter period

2. Place a very basic rate of turn indicator on the GUI, also moving a few exisiting controls to accommodate it
 todo on this would be to softcode the range is measures,  A rib would turn far faster than a vlcc. 

3. Alter the user's interaction with the steering to more accurately reflect follow up mode on a ship.  The rudder can only be moved at a limited speed, but the steering wheel can be moved instantaneously.  To that end the user now controls the "wheel" and the rudder follows it at the rate defined in boat.ini of Ownship the units being degrees per second

RudderAngularVelocity=6

the above example would define the rudder can be moved by the steering gear through a maximum of 6 degrees per second

typical values for a rib woudl be 90, almost instentaneous
for a 100m general cargo ship 2 degrees per second
big old vlcc 1 degree per second 

I hope this meets with your approval

9
I've been playing with doing a model of a real world canal based on a real world example.  I came accross the problem of getting the canal segments to line up, each one being a separate heightmap and texture in each section of terrain.ini each based on googlemap printscreen and crop.

Based on plane sailing formulae

INPUTS from the URL of the google map page
https://www.google.co.uk/maps/@52.9727602,-3.6609794,10z
vvvvv
https://www.google.co.uk/maps/@[LAT_CENTRE],[LONG_CENTRE],[ZOOM]z

and assuming as aspect ratio of 2, as the image I see is twice as wide as it is high



TerrainLatExtent=32768/(60*2^(ZOOM)) ... in decimal degrees

TerrainLongExtent=TerrainLatExtent*2/cos(RADIANS(LAT_CENTRE)) ... in decimal degrees

TerrainLat=LAT_CENTRE-TerrainLatExtent/2

TerrainLong=LONG_CENTRE-TerainLongExtent/2



The above parameters can be put into the terrain.ini file once  you have worked out the values (probably using a spreadsheet)

For the heightmap .... The image can then be resized and cropped to 1025 ... 2049 etc for the heightmap which then needs to be shaded according to contours

For the texture ... The image can then be resized and cropped to 1024 ... 2048 etc

This uses plane sailing formulae as its base which approximates the earths surface at the centre of the map to a flat plane where the "departure" distance east or west is the same at all latitudes of that map (hence its suitability only for relatively small areas)



10
Environment models / Bathymetry Data
« on: November 15, 2017, 10:54:31 AM »
I came across this portal today ...

http://portal.emodnet-bathymetry.eu/mean-depth-full-coverage

where .asc files can be downloaded for selected areas, then converted using the import.exe tool to create .pgm -> then imagemagick to create png for bathymetry modelling in the heightmap.

11
Environment models / Tidal modelling
« on: November 12, 2017, 10:40:49 AM »
Having read the documentation, I understand how the tides ini file can model the height of tide at any given time.   Is there some way, however of modelling the tidal stream , the set and rate of a tide (direction it flows in and the speed that it flows) ?  I was thinking about something like this ...........

if a rising tide sets (flows in at a "heading") of 100 degrees and flows out at 280 degrees
tidal_axis = 100 {the heading of a rising tide}
max_rate = 4  {the maximum speed of a tide}

so speed of a tide at any given time  max_rate * sin (offset + tidal period)
the -ve speed then pertaining to a tidal stream in the opposite direction when ebbing (i.e. 280)


is there an existing way of modelling this ?

12
Feature requests & suggestions / Follow up rudder
« on: July 13, 2017, 09:25:03 AM »
Would it be possible to simulate lag in the rudder.   On a real ship, when the wheel is turned to a rudder setting, then it takes an appreciable time for the actual rudder to move to that position unlike a speed boat where the rudder or outboard engine is linked directly and mechanically to the wheel.  On a large modern ship the wheel is essentially a potentiometer which requests a rudder angle and the rudder is actuated to that requested position by hydraulic rams in the steering room.  On my last ship it took about 20 seconds for the rudder to go from full hard over to full hard over (40 degrees) on the opposite side.  So this could be simply modelled with a parameter of RudderDegreesPerSecond = 4

A bowthruster would also be a nice addition

13
Environment models / .f32 heightmap creation
« on: June 25, 2017, 09:38:44 PM »
Does anyone know of an easy way to create an f32 heightmap from .asc file format strm data ?

14
General Discussion / Compiling under Linux Fedora 23
« on: May 23, 2016, 02:57:40 PM »
I've installed the C++ libraries for gcc ... g++

I've not had any success in compiling bridgecommand

Has anyone else had more success ?

15
Environment models / Memory Access Violation
« on: June 06, 2015, 05:49:07 PM »
https://drive.google.com/folderview?id=0By54Gc3E3B7Pfk9vcC1hdnhDRU1ZNkV4V29kNkhESFhITnhrekRXUUFhZy1oNjgxWk5xNG8&usp=sharing

https://drive.google.com/folderview?id=0By54Gc3E3B7Pfk5yZl9XT2h6QkpWZEhkVlRpbUFWSmxFbFBSUU1UZUF4UElCdU45ZmF4X1U&usp=sharing

I have been trying to develop a scenario and world  but have hit a brick wall.  I have copied onto these links, the contents of the scenario and world subdirectories as I have run out of ideas on why this doesnt work.  If anyone can find the problem I would be grateful.

Pages: [1]